SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO


CREATE PROCEDURE dbo.[DnnProduct_GetPackagesByType]
	@PortalID			int,
	@PackageType		nvarchar(50)
AS
	SELECT *
		FROM   dbo.DnnProduct_Packages
		WHERE (PortalID = @PortalID OR @PortalID IS NULL OR PortalID IS NULL)
			AND  PackageType = @PackageType
		ORDER BY [FriendlyName] ASC
GO
